package com.service.imp;

import com.domain.Addresslist;
import com.github.pagehelper.PageHelper;
import com.mapper.AddresslistMapper;
import com.service.AddresslistService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
@Service
public class AddresslistServiceImp implements AddresslistService {
    @Autowired
    private AddresslistMapper addresslistMapper;
    @Override
    public List<Addresslist> findAll() {

        return addresslistMapper.findAll();
    }

    @Override
    public void insert(Addresslist addresslist) {
        addresslistMapper.insert(addresslist);
    }

    @Override
    public List<Addresslist> findAll(int page, int size) {
//        PageHelper.startPage(page,size);
        return addresslistMapper.findAll();

    }
}
